<?php 
namespace App\Util;
use Illuminate\Support\Facades\URL  as BaseUrl;
class Url
{
     private static $cacheHttpHost;
     /**
      * 获取 http|https://domain/
      * @return string
      */
     public static function getHttpHost()
     {
         if(empty(self::$cacheHttpHost))
         {
             $pu = parse_url(BaseUrl::current());
             self::$cacheHttpHost = $pu['scheme']."://".$pu['host']."/";
         }
         return self::$cacheHttpHost;
     }
}